#ifndef __HTTP_H_
#define __HTTP_H_
#include "j_includes.h"
#include "ModuleManagerDef.h"

class CHttpFilter : public J_RequestFilter
						, public J_VodCommandFilter
{
public:
	CHttpFilter();
	~CHttpFilter();

	static int Maker(J_Obj *&pObj)
	{
		pObj = new CHttpFilter();
		return J_OK;
	}

public:
	///J_ProtocolFilter
	virtual int Parser(const char *request);
	virtual int Convert(const char *pInputData, J_StreamHeader &streamHeader, char *pOutputData, int &nOutLen);
	virtual int SetContext(const J_MediaContext *cxt) { return 0; }
	virtual int GetRetrunVal(char *pRetVal, int &nRetLen);
	virtual int GetStatus() const { return (J_ProParamOk | J_ProConnOk); }

private:
	J_MuxFilter *m_muxFilter;
};

FILTER_BEGIN_MAKER(http)
	FILTER_ENTER_MAKER("HTTP", CHttpFilter::Maker)
FILTER_END_MAKER()

#endif //~__HTTP_H_
